import React, { Component } from 'react';

export default  class App extends Component {
  state = {
    checked:true
  }
  handleChange=(e) => {
    console.log(e.target.checked);
    this.setState({
      checked:e.target.checked,
    })
  };
  render() {
    return (
      <div>
        <input type="checkbox" name="" id=""checked={this.state.checked}
        onChange={this.handleChange}/>
      </div>
    );
  }
}


